package com.lyf.lottery.controller;


import com.github.pagehelper.PageInfo;
import com.lyf.common.api.CommonPage;
import com.lyf.common.api.CommonResult;
import com.lyf.lottery.controller.assembler.OptActivityAssembler;
import com.lyf.lottery.model.po.OptActivity;
import com.lyf.lottery.model.req.OptActivityQuery;
import com.lyf.lottery.model.vo.OptActivityAddVo;
import com.lyf.lottery.model.vo.OptActivityQueryVo;
import com.lyf.lottery.model.vo.OptActivityUpdateVo;
import com.lyf.lottery.model.vo.OptActivityVo;
import com.lyf.lottery.service.OptActivityService;
import com.lyf.lottery.service.RedissonService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

/**
 * OptActivity 接口
 *
 * @author lyf
 **/
@RestController
@Api(tags = "延时队列测试")
@RequestMapping("/delayQueue/")
public class DelayQueueController {

    @Autowired
    private RedissonService redissonService;

    @PostMapping("send")
    @ApiOperation("发送")
    public CommonResult draw(String content) {
        redissonService.addDelay(content);
        return CommonResult.success(true);
    }

}

